﻿

Namespace YahooManaged.Finance.Screener.StockCriterias



    ''' <summary>
    ''' Criteria class for dividend per share
    ''' </summary>
    ''' <remarks></remarks>
    Public Class DividendCriteria
        Inherits StockDigitCriteriaDefinition

        Public Overrides ReadOnly Property DisplayName As String
            Get
                Return "Dividend Criteria"
            End Get
        End Property

        Public Overrides ReadOnly Property CriteriaName As String
            Get
                Return "Dividend"
            End Get
        End Property

        Public Overrides ReadOnly Property CriteriaGroup As StockScreenerCriteriaGroup
            Get
                Return StockScreenerCriteriaGroup.Dividends
            End Get
        End Property
        Public Overrides ReadOnly Property ProvidedQuoteProperties As QuoteProperty()
            Get
                Return {QuoteProperty.Symbol, _
                        QuoteProperty.Name, _
                        QuoteProperty.LastTradePriceOnly, _
                        QuoteProperty.LastTradeTime, _
                        QuoteProperty.MarketCapitalization, _
                        QuoteProperty.TrailingAnnualDividendYield}
            End Get
        End Property
        Public Overrides ReadOnly Property ProvidedScreenerProperties As StockScreenerProperty()
            Get
                Return {StockScreenerProperty.ReturnOnEquity, _
                        StockScreenerProperty.ReturnOnAssets, _
                        StockScreenerProperty.ForwardPriceToEarningsRatio}
            End Get
        End Property

        Public Sub New()
            MyBase.New("4"c)
        End Sub
    End Class


    ''' <summary>
    ''' Criteria class for dividend yield
    ''' </summary>
    ''' <remarks></remarks>
    Public Class YieldCriteria
        Inherits StockDigitCriteriaDefinition

        Public Overrides ReadOnly Property DisplayName As String
            Get
                Return "Yield Criteria"
            End Get
        End Property

        Public Overrides ReadOnly Property CriteriaName As String
            Get
                Return "Yield"
            End Get
        End Property

        Public Overrides ReadOnly Property CriteriaGroup As StockScreenerCriteriaGroup
            Get
                Return StockScreenerCriteriaGroup.Dividends
            End Get
        End Property
        Public Overrides ReadOnly Property ProvidedQuoteProperties As QuoteProperty()
            Get
                Return {QuoteProperty.Symbol, _
                        QuoteProperty.Name, _
                        QuoteProperty.LastTradePriceOnly, _
                        QuoteProperty.LastTradeTime, _
                        QuoteProperty.MarketCapitalization, _
                        QuoteProperty.TrailingAnnualDividendYieldInPercent}
            End Get
        End Property
        Public Overrides ReadOnly Property ProvidedScreenerProperties As StockScreenerProperty()
            Get
                Return {StockScreenerProperty.ReturnOnEquity, _
                        StockScreenerProperty.ReturnOnAssets, _
                        StockScreenerProperty.ForwardPriceToEarningsRatio}
            End Get
        End Property

        Public Sub New()
            MyBase.New("5"c)
        End Sub
    End Class


End Namespace